<template>
	<div>我是头部,{{value}}
  <button @click="pushName()"> 添加数组</button>
  <button @click="getFatherFun"> 我调用父组件中的函数</button>

  </div>
</template>

<script>
	export default{
    name:"title1",
    props:["value"],
		data(){
			return{
        namelist:[]
			}
		},
		components:{

		},
		methods:{
      pushName(){
        this.namelist.push("张三");
      },
      getName(){
        return this.namelist;
      },
      getFatherFun(){
        this.$emit("getFatherData")
      }

		}
	}
</script>

<style>
</style>
